#include "TimerWin32.h"
#include <iostream>
using namespace std;

int main() {
	Timer testTimer = Timer(0);
	testTimer.start();
	testTimer.setTimeScaleFactor(2.0f);

	float cyclesPerSec = Timer::getCyclesPerSecond();
	__int64 timeCyclesBegin = Timer::readCpuTimerCycles();
	while(true) {

		__int64 timeCyclesEnd = Timer::readCpuTimerCycles();
		float dt = (float)(timeCyclesEnd - timeCyclesBegin) / cyclesPerSec;

		testTimer.updateByTime(dt);
		//testTimer.updateByCycles(timeCyclesEnd - timeCyclesBegin);

		cout << "Time: " << testTimer.getTimeCycles() / cyclesPerSec << endl;
		timeCyclesBegin = timeCyclesEnd;
	}

	int i;
	cin >> i;
	return 0;
}